#ifndef WIDRAWDATA_H_
#define WIDRAWDATA_H_

#define SYVIEW_RAWDATA 0

#include "scHeader.h"
#include <QLabel>
#include "FactoryView.h"
#include "WidSybilView.h"
#include "ui_widRawData.h"

namespace sybilpm
{

class TransRawData : public TransSybilView
{
	Q_DECLARE_TR_FUNCTIONS(TransRawData)
public:
	virtual ~TransRawData() {}
	virtual std::string getTechnicalName() const {return std::string("RawData");}
	virtual QString getDisplayName() const {return tr("raw data");}
	virtual QString getDescription() const {return tr("display unformatted XML data");}
};

class WidRawData : public WidSybilView
{
	Q_OBJECT
public:
	WidRawData(QWidget * parent = 0);
	virtual ~WidRawData();
	virtual int getViewId() const {return SYVIEW_RAWDATA;};
public slots:
	virtual void dataChangedSl(unsigned long transactionId) {Q_UNUSED(transactionId)} // intentionally empty - we use serverResponseSig
	virtual void dataMarkSl() {} // nothing to mark
	void requestChangedSl();

private:
	Ui::widRawData ui;
};

namespace
{
WidSybilView * createRawData(QWidget * parent) {return new WidRawData(parent);}
TransSybilView * createTransRawData() {return new TransRawData();}
const bool inFactory(FactoryView::get()->addProduct(SYVIEW_RAWDATA, createRawData, createTransRawData));
}
} // namespace sybilpm

#endif /*WIDRAWDATA_H_*/
